package com.wen.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.wen.pojo.Product;
import com.baomidou.mybatisplus.extension.service.IService;
import com.wen.pojo.StockDetails;
import com.wen.pojo.dto.ProductAndStockDetails;
import com.wen.pojo.dto.ProductDto;
import com.wen.pojo.vo.ProductVo;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author xie
 * @since 2023-04-24
 */
public interface ProductService extends IService<Product> {

    Page<Product> queryPage(ProductDto dto, Integer pageNum, Integer size);

    int getProductAdd(Product product);

    List<StockDetails> getSelStockDetails(String id);

    Page<Product> queryByPage(Long pageNum, Long pageSize);


    int getUpdateProduct(String stock, String id);

    int getUpdateOnff(String id,Integer onff);



    /**
     * 带条件分页查询
     * @param pageNum
     * @param pageSize
     * @param productVo
     * @return
     */
    Page<Product> pageListMedicinesCondition(ProductVo productVo, Long pageNum, Long pageSize);
}
